<?php
namespace BP\Sys;
require_once("BP/En/Map.php");
class GroupEnsTemplate extends EntityOID {
	public function getEnsName () 
	{
		return $this->GetValStringByKey(GroupEnsTemplateAttr::$EnsName);
	}
	public function setEnsName ($value) // [String value]
	{
		$this->SetValByKey(GroupEnsTemplateAttr::$EnsName, $value);
	}
	public function getOperateCol () 
	{
		return $this->GetValStringByKey(GroupEnsTemplateAttr::$OperateCol);
	}
	public function setOperateCol ($value) // [String value]
	{
		$this->SetValByKey(GroupEnsTemplateAttr::$OperateCol, $value);
	}
	public function getAttrs () 
	{
		return $this->GetValStringByKey(GroupEnsTemplateAttr::$Attrs);
	}
	public function setAttrs ($value) // [String value]
	{
		$this->SetValByKey(GroupEnsTemplateAttr::$Attrs, $value);
	}
	public function getName () 
	{
		return $this->GetValStringByKey(GroupEnsTemplateAttr::$Name);
	}
	public function setName ($value) // [String value]
	{
		$this->SetValByKey(GroupEnsTemplateAttr::$Name, $value);
	}
	public function getEnName () 
	{
		return $this->GetValStringByKey(GroupEnsTemplateAttr::$EnName);
	}
	public function setEnName ($value) // [String value]
	{
		$this->SetValByKey(GroupEnsTemplateAttr::$EnName, $value);
	}
	public function getRec () 
	{
		return $this->GetValStringByKey(GroupEnsTemplateAttr::$Rec);
	}
	public function setRec ($value) // [String value]
	{
		$this->SetValByKey(GroupEnsTemplateAttr::$Rec, $value);
	}
	public function getHisUAC () 
	{
		$uac = new UAC();
		$uac->IsUpdate =  TRUE ;
		$uac->IsView =  TRUE ;
		return parent->getHisUAC();
	}
	public static function constructor__ () 
	{
		$me = new self();
		return $me;
	}
	public function getEnMap () 
	{
		if (($this->get_enMap() != NULL))
		{
			return $this->get_enMap();
		}
		$map = new Map("Sys_GroupEnsTemplate", "报表模板");
		$map->setDepositaryOfEntity($Depositary->None);
		$map->setEnType($EnType->Sys);
		$map->AddTBIntPKOID();
		$map->AddTBString(GroupEnsTemplateAttr::$EnName, NULL, "表称",  FALSE ,  FALSE , 0, 500, 20);
		$map->AddTBString(GroupEnsTemplateAttr::$Name, NULL, "报表�?",  TRUE ,  FALSE , 0, 500, 20);
		$map->AddTBString(GroupEnsTemplateAttr::$EnsName, NULL, "报表类名",  FALSE ,  TRUE , 0, 90, 10);
		$map->AddTBString(GroupEnsTemplateAttr::$OperateCol, NULL, "操作属�??",  FALSE ,  TRUE , 0, 90, 10);
		$map->AddTBString(GroupEnsTemplateAttr::$Attrs, NULL, "运算属�??",  FALSE ,  TRUE , 0, 90, 10);
		$map->AddTBString(GroupEnsTemplateAttr::$Rec, NULL, "记录�?",  FALSE ,  TRUE , 0, 90, 10);
		$this->set_enMap($map);
		return $this->get_enMap();
	}
	public function Search ($fk_emp, $className, $attrs) // [String fk_emp, String className, String attrs]
	{
		$qo = new QueryObject($this);
		$qo->AddWhere(GroupEnsTemplateAttr::$Rec, $fk_emp);
		$qo->addAnd();
		$qo->AddWhere(GroupEnsTemplateAttr::$Attrs, $className);
		$qo->addAnd();
		$qo->AddWhere(GroupEnsTemplateAttr::$EnsName, $className);
		return $qo->DoQuery();
	}
}
?>
